home *** CD-ROM | disk | FTP | other *** search
- .386p
- jumps
-
- code32 segment para public use32
- assume cs:code32, ds:code32
-
- Include Pmode.inc
- ;▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
- ; Global Definitions for the Player
- ;▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
- Global AMS_Init:Near,AMS_LoadModule:Near,AMS_ErrorHandler:Near,AMS_ShutDown:Near
- Global AMS_ReadCommandLine:Near,AMS_StartModule:Near,AMS_StopModule:Near
-
- Global ModName:Byte,PositionJump:Byte
- Global LoadOffset:Dword,OwnMemory:Dword
-
- Public _Main
- ;▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒
- ; The Main Routine
- ;▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒
- _Main:
- call AMS_Init ;Init everyting
- call AMS_ReadCommandLine ;Read the commandline
- ;and put it in "Modname"
- call AMS_LoadModule ;Load the modules specified in "Modname"
- call AMS_StartModule ;Start the playing.
-
- Waiting:
- in al,60h
- cmp al,1
- jnz Waiting
-
-
- call AMS_StartModule ;Stops the playing.
- call AMS_ShutDown ;Shut down the MusicSystem
-
- jmp _exit
-
-
- ;──────────────────────────────────────────────────────────────────────────────
- ;When reaching this code, some Problem occured.
- ;
- ; * ESI points to a text string that describes the error
- ;
- ; You may replace the following code with an own errorhandler if you wish,
- ; This is just an example.
- ;
- ;──────────────────────────────────────────────────────────────────────────────
- AMS_Errorhandler:
- ; mov V86R_AX,3 ;Set Screen Mode
- ; mov al,10h
- ; int 33h
- call PrintText
- jmp _Exit
-
-
- ;─────────────────────────────
- ;Prints a text in textmode
- ;Calls: ESI = Offset to text
- ;─────────────────────────────
- PrintText Proc Near
- Pushad
- mov edx,esi
- add edx,_code32a
- ror edx,4
- mov V86R_DS,dx
- shr edx,28
- mov V86R_DX,dx
- mov V86R_AH,9
- mov al,21h
- int 33h
- Popad
- Ret
- PrintText EndP
-
-
-
- code32 ends
- end
-